<template>
  <section class="to-top-box">
    <p class="text-c" @click="handleToIndex">
      <i class="iconfont iconshouyeweixuanzhongx"></i>
      <span>回首页</span>
    </p>

  </section>
</template>

<script type="text/ecmascript-6">
  export default {
    data() {
      return {

      }
    },
    methods: {
      handleToIndex(){
        this.$router.push({
          path:'/index'
        })
      }
    },
  }
</script>

<style scoped lang="scss">
  @import '../assets/css/base.scss';

  .to-top-box{
    position: fixed;
    bottom:101px;
    right:12px;

    p{
      background-color: rgba(0,0,0,.5);
      width: 44px;
      height: 44px;
      border-radius: 50%;
      color: #fff;
      padding-top: 3px;
      box-sizing: border-box;

      i{
        display: block;
        font-size: 24px;
      }

      span{
        display: block;
        font-size: 8px;
      }
    }
  }
</style>
